<template>
	<view>
		<view class="eventdata">
			<view>
				<uni-collapse ref="collapse" accordion="true">
					<uni-collapse-item :showArrow="true" :title="wfAssetDamage+' : '+wfAssetDamage_Length"
						:showAnimation="true" titleBorder="true">
						<view class="content">
							<view v-if="event.length!=0">
								<view class="event_1" v-for="(item,index) in wfAssetDamageList" :key="index"
									@click="details(item)">
									<view class="image">
										<image :src="item.img" mode="aspectFit"></image>
									</view>
									<view class="tree"></view>
									<view class="event">
										<view class="name">
											<text class="text">{{item.processInsName}}</text>
										</view>
										<view class="date">
											<text class="text">{{item.startTime}}</text>
										</view>
										<view class="handle">
											<text class="text">提交人:<text>{{item.operatorText}}</text></text>
										</view>

									</view>
								</view>
							</view>
						</view>
					</uni-collapse-item>
					<uni-collapse-item :title="wfAssetMaintain+' : '+wfAssetMaintain_Length" :showArrow="true"
						:showAnimation="true" titleBorder="true">
						<view class="content">
							<view v-if="event.length!=0">
								<view class="event_1" v-for="(item,index) in wfAssetMaintainList" :key="index"
									@click="details(item)">
									<view class="image">
										<image :src="item.img" mode="aspectFit"></image>
									</view>
									<view class="tree"></view>
									<view class="event">
										<view class="name">
											<!-- <text class="text">{{item.flowName}}</text> -->
											<text class="text">{{item.processInsName}}</text>
										</view>
										<view class="date">
											<!-- <text class="text">{{item.flowNo}}</text> -->
											<text class="text">{{item.startTime}}</text>
										</view>
										<view class="handle">
											<text class="text">提交人:<text>{{item.operatorText}}</text></text>
										</view>

									</view>

								</view>
								<!-- <view class="bottom">
									<text>暂无更多数据</text>
								</view> -->
							</view>
						</view>
					</uni-collapse-item>
					<uni-collapse-item :title="wfReservation+' : '+wfReservation_Length" :showArrow="true"
						:showAnimation="true" titleBorder="true">
						<view class="content">
							<view v-if="event.length!=0">
								<view class="event_1" v-for="(item,index) in wfReservationList" :key="index"
									@click="details(item)">
									<view class="image">
										<image :src="item.img" mode="aspectFit"></image>
									</view>
									<view class="tree"></view>
									<view class="event">
										<view class="name">
											<!-- <text class="text">{{item.flowName}}</text> -->
											<text class="text">{{item.processInsName}}</text>
										</view>
										<view class="date">
											<!-- <text class="text">{{item.flowNo}}</text> -->
											<text class="text">{{item.startTime}}</text>
										</view>
										<view class="handle">
											<text class="text">提交人:<text>{{item.operatorText}}</text></text>
										</view>

									</view>
								</view>
								<!-- <view class="bottom">
									<text>暂无更多数据</text>
								</view> -->
							</view>
						</view>
					</uni-collapse-item>
					<uni-collapse-item :title="wfAssetPlaceChange+' : '+wfAssetPlaceChange_Length" :showArrow="true"
						:showAnimation="true" titleBorder="true">
						<view class="content">
							<view v-if="event.length!=0">
								<view class="event_1" v-for="(item,index) in wfAssetPlaceChangeList" :key="index"
									@click="details(item)">
									<view class="image">
										<image :src="item.img" mode="aspectFit"></image>
									</view>
									<view class="tree"></view>
									<view class="event">
										<view class="name">
											<!-- <text class="text">{{item.flowName}}</text> -->
											<text class="text">{{item.processInsName}}</text>
										</view>
										<view class="date">
											<!-- <text class="text">{{item.flowNo}}</text> -->
											<text class="text">{{item.startTime}}</text>
										</view>
										<view class="handle">
											<text class="text">提交人:<text>{{item.operatorText}}</text></text>
										</view>

									</view>
								</view>
								<!-- <view class="bottom">
									<text>暂无更多数据</text>
								</view> -->
							</view>
						</view>
					</uni-collapse-item>
					<uni-collapse-item :title="wfAgreement+' : '+wfAgreement_Length" :showArrow="true"
						:showAnimation="true" titleBorder="true">
						<view class="content">
							<view v-if="event.length!=0">
								<view class="event_1" v-for="(item,index) in wfAgreementList" :key="index"
									@click="details(item)">
									<view class="image">
										<image :src="item.img" mode="aspectFit"></image>
									</view>
									<view class="tree"></view>
									<view class="event">
										<view class="name">
											<!-- <text class="text">{{item.flowName}}</text> -->
											<text class="text">{{item.processInsName}}</text>
										</view>
										<view class="date">
											<!-- <text class="text">{{item.flowNo}}</text> -->
											<text class="text">{{item.startTime}}</text>
										</view>
										<view class="handle">
											<text class="text">提交人:<text>{{item.operatorText}}</text></text>
										</view>

									</view>
								</view>
								<!-- <view class="bottom">
									<text>暂无更多数据</text>
								</view> -->
							</view>
						</view>
					</uni-collapse-item>
					<uni-collapse-item :title="wfStoreApply+' : '+wfStoreApply_Length" :showArrow="true"
						:showAnimation="true" titleBorder="true">
						<view class="content">
							<view v-if="event.length!=0">
								<view class="event_1" v-for="(item,index) in wfStoreApplyList" :key="index"
									@click="details(item)">
									<view class="image">
										<image :src="item.img" mode="aspectFit"></image>
									</view>
									<view class="tree"></view>
									<view class="event">
										<view class="name">
											<!-- <text class="text">{{item.flowName}}</text> -->
											<text class="text">{{item.processInsName}}</text>
										</view>
										<view class="date">
											<!-- <text class="text">{{item.flowNo}}</text> -->
											<text class="text">{{item.startTime}}</text>
										</view>
										<view class="handle">
											<text class="text">提交人:<text>{{item.operatorText}}</text></text>
										</view>

									</view>
								</view>
								<!-- <view class="bottom">
									<text>暂无更多数据</text>
								</view> -->
							</view>
						</view>
					</uni-collapse-item>
					<uni-collapse-item :title="wfSubscription+' : '+wfSubscription_Length" :showArrow="true"
						:showAnimation="true" titleBorder="true">
						<view class="content">
							<view v-if="event.length!=0">
								<view class="event_1" v-for="(item,index) in wfSubscriptionList" :key="index"
									@click="details(item)">
									<view class="image">
										<image :src="item.img" mode="aspectFit"></image>
									</view>
									<view class="tree"></view>
									<view class="event">
										<view class="name">
											<!-- <text class="text">{{item.flowName}}</text> -->
											<text class="text">{{item.processInsName}}</text>
										</view>
										<view class="date">
											<!-- <text class="text">{{item.flowNo}}</text> -->
											<text class="text">{{item.startTime}}</text>
										</view>
										<view class="handle">
											<text class="text">提交人:<text>{{item.operatorText}}</text></text>
										</view>

									</view>
								</view>
								<!-- <view class="bottom">
									<text>暂无更多数据</text>
								</view> -->
							</view>
						</view>
					</uni-collapse-item>
					<uni-collapse-item :title="wfStoreCheck+' : '+wfStoreCheck_Length" :showArrow="true"
						:showAnimation="true" titleBorder="true">
						<view class="content">
							<view v-if="event.length!=0">
								<view class="event_1" v-for="(item,index) in wfStoreCheckList" :key="index"
									@click="details(item)">
									<view class="image">
										<image :src="item.img" mode="aspectFit"></image>
									</view>
									<view class="tree"></view>
									<view class="event">
										<view class="name">
											<!-- <text class="text">{{item.flowName}}</text> -->
											<text class="text">{{item.processInsName}}</text>
										</view>
										<view class="date">
											<!-- <text class="text">{{item.flowNo}}</text> -->
											<text class="text">{{item.startTime}}</text>
										</view>
										<view class="handle">
											<text class="text">提交人:<text>{{item.operatorText}}</text></text>
										</view>

									</view>
								</view>
								<!-- <view class="bottom">
									<text>暂无更多数据</text>
								</view> -->
							</view>
						</view>
					</uni-collapse-item>
					<uni-collapse-item :title="wfAssetChange+' : '+wfAssetChange_Length" :showArrow="true"
						:showAnimation="true" titleBorder="true">
						<view class="content">
							<view v-if="event.length!=0">
								<view class="event_1" v-for="(item,index) in wfAssetChangeList" :key="index"
									@click="details(item)">
									<view class="image">
										<image :src="item.img" mode="aspectFit"></image>
									</view>
									<view class="tree"></view>
									<view class="event">
										<view class="name">
											<!-- <text class="text">{{item.flowName}}</text> -->
											<text class="text">{{item.processInsName}}</text>
										</view>
										<view class="date">
											<!-- <text class="text">{{item.flowNo}}</text> -->
											<text class="text">{{item.startTime}}</text>
										</view>
										<view class="handle">
											<text class="text">提交人:<text>{{item.operatorText}}</text></text>
										</view>

									</view>
								</view>
								<!-- <view class="bottom">
									<text>暂无更多数据</text>
								</view> -->
							</view>
						</view>
					</uni-collapse-item>
					<uni-collapse-item :title="wfAccompany+' : '+wfAccompany_Length" :showArrow="true"
						:showAnimation="true" titleBorder="true">
						<view class="content">
							<view v-if="event.length!=0">
								<view class="event_1" v-for="(item,index) in wfAccompanyList" :key="index"
									@click="details(item)">
									<view class="image">
										<image :src="item.img" mode="aspectFit"></image>
									</view>
									<view class="tree"></view>
									<view class="event">
										<view class="name">
											<!-- <text class="text">{{item.flowName}}</text> -->
											<text class="text">{{item.processInsName}}</text>
										</view>
										<view class="date">
											<!-- <text class="text">{{item.flowNo}}</text> -->
											<text class="text">{{item.startTime}}</text>
										</view>
										<view class="handle">
											<text class="text">提交人:<text>{{item.operatorText}}</text></text>
										</view>

									</view>
								</view>
								<!-- <view class="bottom">
									<text>暂无更多数据</text>
								</view> -->
							</view>
						</view>
					</uni-collapse-item>
				</uni-collapse>
			</view>
			<view class="whole" v-if="event.length==0">
				<image class="image" src="/static/image/zanwushuju@2x.png" mode="aspectFit"></image>
				<text>暂无数据</text>
			</view>

		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				event: [{
					value: 0,
				}],
				times: [],
				wfAssetDamage: "物资报损审批待办",
				wfAssetMaintain: "物资报修审批待办",
				wfReservation: "预定审批待办",
				wfAssetPlaceChange: "资产落位变更审批待办",
				wfAgreement: "服务协议签订审批待办",
				wfStoreApply: "物资领用审批待办",
				wfSubscription: "认购审批待办",
				wfStoreCheck: "库存校正审批待办",
				wfAssetChange: "资产调拨审批待办",
				wfAccompany: "陪住人审批待办",
				wfAssetDamageList: [], //资产报损列表1
				wfReservationList: [], //预定列表1
				wfSubscriptionList: [], //认购列表1
				wfStoreApplyList: [], //物资领用列表1
				wfStoreCheckList: [], //库存校正列表1
				wfAgreementList: [], //服务协议签订列表1
				wfAssetChangeList: [], //资产调拨列表
				wfAssetPlaceChangeList: [], //资产落位变更列表1
				wfAssetMaintainList: [], //资产报修列表1
				wfAccompanyList: [], //陪住人列表1
				wfReservation_Length: 0, //预定
				wfSubscription_Length: 0, //认购
				wfStoreApply_Length: 0, //物资领用
				wfStoreCheck_Length: 0, //库存校正
				wfAgreement_Length: 0, //服务协议签订
				wfAssetChange_Length: 0, //资产调拨
				wfAssetPlaceChange_Length: 0, //资产落位变更
				wfAssetDamage_Length: 0, //资产报损
				wfAssetMaintain_Length: 0, //资产报修
				wfAccompany_Length: 0, //陪住人

			}
		},
		onLoad() {
			uni.startPullDownRefresh();
			this.toDoEvent();
		},
		onShow() {
			this.onSocketMessage()
			// this.toDoEvent();
			//从信息页面返回后跳回上次页面的滚动值的长度
			uni.getStorage({
				key: "newsTop",
				success: (res) => {
					// console.log(res.data);
					var timer = setTimeout(() => {
						uni.pageScrollTo({
							scrollTop: res.data, //距离页面顶部的距离
							duration: 0
						});
						clearTimeout(timer);
					}, 100)
				}
			})

		},
		onPullDownRefresh() {
			console.log("下拉刷新了");
			this.wfAssetDamageList = [];
			this.wfReservationList = [];
			this.wfSubscriptionList = [];
			this.wfStoreApplyList = [];
			this.wfStoreCheckList = [];
			this.wfAgreementList = [];
			this.wfAssetChangeList = [];
			this.wfAssetPlaceChangeList = [];
			this.wfAssetMaintainList = [];
			this.wfAccompanyList = [];
			this.wfReservation_Length = 0;
			this.wfSubscription_Length = 0;
			this.wfStoreApply_Length = 0;
			this.wfStoreCheck_Length = 0;
			this.wfAgreement_Length = 0;
			this.wfAssetChange_Length = 0;
			this.wfAssetPlaceChange_Length = 0;
			this.wfAssetDamage_Length = 0;
			this.wfAssetMaintain_Length = 0;
			this.wfAccompany_Length = 0;
			this.toDoEvent();
			setTimeout(function() {
				uni.stopPullDownRefresh();
			}, 1000);
		},
		// scrollTop是data中定义的变量，可以将页面的滚动值赋值保存下来。
		onPageScroll(e) {
			this.scrollTop = e.scrollTop;
			// console.log(this.scrollTop)
		},
		methods: {
			//	打开成功监听服务器返回的告警信息
			onSocketMessage() {
				uni.onSocketMessage(res => {
					// console.log(JSON.parse(res.data));
					const data = JSON.parse(res.data)
					if (data.code == "99") {
						if (data.hasOwnProperty("msg")) {
							if (data.msg != 'ping') {
								getApp().globalData.getSocketMsg(res.data);
								if (data.msgType == "com.plugins.pending.open") {
									console.log(data);
									this.toDoEvent();
								}
							}
						}
					}
				});
			},
			async toDoEvent() {
				const res = await this
					.$myRequest({ //await 关键字 只能放在 async 函数内部， await关键字的作用 就是获取 Promise中返回的内容， 获取的是Promise函数中resolve或者reject的值
						url: '/api-flow/api/selectTaskInsListPending',
						method: "get",
						data: {

						},
					})
				if (res.success == true) {
					this.event = res.data.result
					// console.log("this.event:", this.event);
					// console.log("this.event.length", this.event.length);
					for (let i = 0; i < this.event.length; i++) {
						if (this.event[i].flowNo == "wfAssetDamage") { //资产报损审核流程
							// console.log("资产报损时间:", res.data.result[i].startTime)
							// this.times[i]=new Date(res.data.result[i].startTime)
							// let ti=this.times[i].getTime()
							// console.log("转换时间戳：",ti)
							// if(ti>1){
							// 	console.log("比较：",ti)
							// }
							this.wfAssetDamage_Length++;
							this.event[i].img = "/static/image/matter@2x.png";
							this.wfAssetDamageList.push(this.event[i]);
							// console.log("this.wfAssetDamageList", this.wfAssetDamageList)
						} else if (this.event[i].flowNo == "wfAssetMaintain") { //资产报修审核流程
							this.wfAssetMaintain_Length++;
							this.event[i].img = "/static/image/matter@2x.png";
							this.wfAssetMaintainList.push(this.event[i]);
						} else if (this.event[i].flowNo == "wfAssetChange") { //资产调拨审核流程
							this.wfAssetChange_Length++;
							this.event[i].img = "/static/image/Endowment@2x.png";
							this.wfAssetChangeList.push(this.event[i]);
						} else if (this.event[i].flowNo == "wfStoreApply") { //物资领用流程
							this.wfStoreApply_Length++;
							this.event[i].img = "/static/image/matter@2x.png";
							this.wfStoreApplyList.push(this.event[i]);
						} else if (this.event[i].flowNo == "wfReservation") { //预定流程
							this.wfReservation_Length++;
							this.event[i].img = "/static/image/Anticipate@2x.png";
							this.wfReservationList.push(this.event[i]);
						} else if (this.event[i].flowNo == "wfSubscription") { //认购流程
							this.wfSubscription_Length++;
							this.event[i].img = "/static/image/recognize@2x.png";
							this.wfSubscriptionList.push(this.event[i]);
						} else if (this.event[i].flowNo == "wfStoreCheck") { //库存校正流程
							this.wfStoreCheck_Length++;
							this.event[i].img = "/static/image/library@2x.png";
							this.wfStoreCheckList.push(this.event[i]);
						} else if (this.event[i].flowNo == "wfAgreement") { //服务协议签订审核流程
							this.wfAgreement_Length++;
							this.event[i].img = "/static/image/clothes@2x.png";
							this.wfAgreementList.push(this.event[i]);
						} else if (this.event[i].flowNo == "wfAssetPlaceChange") { //资产落位变更审核流程
							this.wfAssetPlaceChange_Length++;
							this.event[i].img = "/static/image/Endowment@2x.png";
							this.wfAssetPlaceChangeList.push(this.event[i]);
						} else if (this.event[i].flowNo == "wfAccompany") { //陪住人审核流程
							this.wfAccompany_Length++;
							this.event[i].img = "/static/image/Endowment@2x.png";
							this.wfAccompanyList.push(this.event[i]);
						}
					}
				}
				this.wfAssetDamageList.sort(function(a, b) {
					let obj1 = a['startTime']
					let obj2 = b['startTime']
					const val1 = Math.floor(new Date(obj1).getTime() / 1000)
					const val2 = Math.floor(new Date(obj2).getTime() / 1000)
					return val1 - val2
					// return val2 - val1
				})
				// for (let i = 0; i < this.wfAssetDamageList.length; i++) {
				// 	console.log("资产报损时间降序：", this.wfAssetDamageList[i].startTime)
				// }
				console.log("资产报损待办：", this.wfAssetDamage_Length);
				// console.log("资产报损列表：", this.wfAssetDamageList);

				this.wfAssetMaintainList.sort(function(a, b) {
					let obj1 = a['startTime']
					let obj2 = b['startTime']
					const val1 = Math.floor(new Date(obj1).getTime() / 1000)
					const val2 = Math.floor(new Date(obj2).getTime() / 1000)
					return val1 - val2
					// return val2 - val1
				})
				// for (let i = 0; i < this.wfAssetMaintainList.length; i++) {
				// 	console.log("资产报修时间降序：", this.wfAssetMaintainList[i].startTime)
				// }
				console.log("资产报修待办：", this.wfAssetMaintain_Length);
				// console.log("资产报修列表：", this.wfAssetMaintainList);

				this.wfReservationList.sort(function(a, b) {
					let obj1 = a['startTime']
					let obj2 = b['startTime']
					const val1 = Math.floor(new Date(obj1).getTime() / 1000)
					const val2 = Math.floor(new Date(obj2).getTime() / 1000)
					return val1 - val2
					// return val2 - val1
				})
				// for (let i = 0; i < this.wfReservationList.length; i++) {
				// 	console.log("预定时间降序：", this.wfReservationList[i].startTime)
				// }
				console.log("预定待办：", this.wfReservation_Length);

				this.wfAssetChangeList.sort(function(a, b) {
					let obj1 = a['startTime']
					let obj2 = b['startTime']
					const val1 = Math.floor(new Date(obj1).getTime() / 1000)
					const val2 = Math.floor(new Date(obj2).getTime() / 1000)
					return val1 - val2
					// return val2 - val1
				})
				// for (let i = 0; i < this.wfAssetChangeList.length; i++) {
				// 	console.log("资产调拨时间降序：", this.wfAssetChangeList[i].startTime)
				// }
				console.log("资产调拨待办：", this.wfAssetChange_Length);

				this.wfAgreementList.sort(function(a, b) {
					let obj1 = a['startTime']
					let obj2 = b['startTime']
					const val1 = Math.floor(new Date(obj1).getTime() / 1000)
					const val2 = Math.floor(new Date(obj2).getTime() / 1000)
					return val1 - val2
					// return val2 - val1
				})
				// for (let i = 0; i < this.wfAgreementList.length; i++) {
				// 	console.log("服务协议签订时间降序：", this.wfAgreementList[i].startTime)
				// }
				console.log("服务协议签订待办：", this.wfAgreement_Length);

				this.wfStoreApplyList.sort(function(a, b) {
					let obj1 = a['startTime']
					let obj2 = b['startTime']
					const val1 = Math.floor(new Date(obj1).getTime() / 1000)
					const val2 = Math.floor(new Date(obj2).getTime() / 1000)
					return val1 - val2
					// return val2 - val1
				})
				// for (let i = 0; i < this.wfStoreApplyList.length; i++) {
				// 	console.log("物资领用时间降序：", this.wfStoreApplyList[i].startTime)
				// }
				console.log("物资领用待办：", this.wfStoreApply_Length);

				this.wfSubscriptionList.sort(function(a, b) {
					let obj1 = a['startTime']
					let obj2 = b['startTime']
					const val1 = Math.floor(new Date(obj1).getTime() / 1000)
					const val2 = Math.floor(new Date(obj2).getTime() / 1000)
					return val1 - val2
					// return val2 - val1
				})
				// for (let i = 0; i < this.wfSubscriptionList.length; i++) {
				// 	console.log("认购时间降序：", this.wfSubscriptionList[i].startTime)
				// }
				console.log("认购待办：", this.wfSubscription_Length);

				this.wfStoreCheckList.sort(function(a, b) {
					let obj1 = a['startTime']
					let obj2 = b['startTime']
					const val1 = Math.floor(new Date(obj1).getTime() / 1000)
					const val2 = Math.floor(new Date(obj2).getTime() / 1000)
					return val1 - val2
					// return val2 - val1
				})
				// for (let i = 0; i < this.wfStoreCheckList.length; i++) {
				// 	console.log("库存校正时间降序：", this.wfStoreCheckList[i].startTime)
				// }
				console.log("库存校正待办：", this.wfStoreCheck_Length);

				this.wfAssetPlaceChangeList.sort(function(a, b) {
					let obj1 = a['startTime']
					let obj2 = b['startTime']
					const val1 = Math.floor(new Date(obj1).getTime() / 1000)
					const val2 = Math.floor(new Date(obj2).getTime() / 1000)
					return val1 - val2
					// return val2 - val1
				})
				// for (let i = 0; i < this.wfAssetPlaceChangeList.length; i++) {
				// 	console.log("资产落位变更时间降序：", this.wfAssetPlaceChangeList[i].startTime)
				// }
				console.log("资产落位变更待办：", this.wfAssetPlaceChange_Length);

				this.wfAccompanyList.sort(function(a, b) {
					let obj1 = a['startTime']
					let obj2 = b['startTime']
					const val1 = Math.floor(new Date(obj1).getTime() / 1000)
					const val2 = Math.floor(new Date(obj2).getTime() / 1000)
					return val1 - val2
					// return val2 - val1
				})
				// for (let i = 0; i < this.wfAccompanyList.length; i++) {
				// 	console.log("陪住人时间降序：", this.wfAccompanyList[i].startTime)
				// }
				console.log("陪住人待办：", this.wfAccompany_Length);

				console.log("总计待办：", this.wfAssetDamage_Length + this.wfAssetMaintain_Length + this
					.wfAssetChange_Length + this.wfStoreApply_Length + this.wfReservation_Length + this
					.wfSubscription_Length + this.wfStoreCheck_Length + this.wfAgreement_Length + this
					.wfAssetPlaceChange_Length + this.wfAccompany_Length);
			},
			details(item) {
				console.log(item.flowNo, item.flowName)
				if (item.flowNo == "wfAssetPlaceChange") {
					uni.navigateTo({
						url: '/pages/approve/approvalDetails/changeOfAssetLocation?businessId=' + item
							.taskInstanceId +
							'&processInsName=' + item.processInsName + '&flowNo=' + item.flowNo +
							'&flowName=' +
							item.flowName
					})
				} else if (item.flowNo == "wfAssetDamage") {
					uni.navigateTo({
						url: '/pages/approve/approvalDetails/lossReporting?businessId=' + item
							.taskInstanceId +
							'&processInsName=' + item.processInsName + '&flowNo=' + item.flowNo +
							'&flowName=' +
							item.flowName
					})
				} else if (item.flowNo == "wfAssetMaintain") {
					uni.navigateTo({
						url: '/pages/approve/approvalDetails/reportForRepair?businessId=' + item
							.taskInstanceId +
							'&processInsName=' + item.processInsName + '&flowNo=' + item.flowNo +
							'&flowName=' +
							item.flowName
					})
				} else if (item.flowNo == "wfAssetChange") {
					uni.navigateTo({
						url: '/pages/approve/approvalDetails/changesInAssets?businessId=' + item
							.taskInstanceId +
							'&processInsName=' + item.processInsName + '&flowNo=' + item.flowNo +
							'&flowName=' +
							item.flowName
					})
				} else if (item.flowNo == "wfStoreApply") {
					uni.navigateTo({
						url: '/pages/approve/approvalDetails/materialRequisition?businessId=' + item
							.taskInstanceId + '&processInsName=' + item.processInsName + '&flowNo=' +
							item.flowNo +
							'&flowName=' + item.flowName
					})
				} else if (item.flowNo == "wfReservation") {
					uni.navigateTo({
						url: '/pages/approve/approvalDetails/reserve?businessId=' + item
							.taskInstanceId +
							'&processInsName=' + item.processInsName + '&flowNo=' + item.flowNo +
							'&flowName=' +
							item.flowName
					})
				} else if (item.flowNo == "wfSubscription") {
					uni.navigateTo({
						url: '/pages/approve/approvalDetails/subscription?businessId=' + item
							.taskInstanceId +
							'&processInsName=' + item.processInsName + '&flowNo=' + item.flowNo +
							'&flowName=' +
							item.flowName
					})
				} else if (item.flowNo == "wfStoreCheck") {
					uni.navigateTo({
						url: '/pages/approve/approvalDetails/inventoryCorrection?businessId=' + item
							.taskInstanceId + '&processInsName=' + item.processInsName + '&flowNo=' +
							item.flowNo +
							'&flowName=' + item.flowName
					})
				} else if (item.flowNo == "wfAgreement") {
					uni.navigateTo({
						url: '/pages/approve/approvalDetails/serviceSigning?businessId=' + item
							.taskInstanceId +
							'&processInsName=' + item.processInsName + '&flowNo=' + item.flowNo +
							'&flowName=' +
							item.flowName
					})
				} else if (item.flowNo == "wfAccompany") {
					uni.navigateTo({
						url: '/pages/approve/approvalDetails/wfAccompany?businessId=' + item
							.taskInstanceId +
							'&processInsName=' + item.processInsName + '&flowNo=' + item.flowNo +
							'&flowName=' +
							item.flowName
					})
				}
				uni.setStorage({
					key: "newsTop",
					data: this.scrollTop
				})
			},
		}
	}
</script>

<style lang="scss">
	.eventdata {
		font-size: 28rpx;

		.whole {
			text-align: center;
			font-size: 60rpx;
			color: #959595;

			.image {
				margin: 320rpx 0 50rpx 0;
				width: 100%;
				height: 350rpx;
			}
		}

		.event_1 {
			display: flex;
			font-size: 28rpx;
			margin-top: 25rpx;
			width: 100%;
			height: 210rpx;
			font-size: 28rpx;
			background-color: #ffffff;
			align-items: center;

			.image {
				height: 210rpx;
				width: 140rpx;
				display: flex;
				margin-right: 20rpx;
				align-items: center;

				image {
					margin: 0;
					width: 130rpx;
					left: 30rpx;
					height: 180rpx;
				}
			}

			.tree {
				width: 2px;
				height: 80px;
				background: darkgray;
				margin: 0 30rpx;
			}

			.event {



				.handle {
					height: 80rpx;
					line-height: 80rpx;
					width: 100%;
					color: #959595;

					.text {
						position: absolute;

						text {
							margin-left: 10rpx;
							font-size: 34rpx;
							color: #109EF8;
						}
					}


				}

				.date {
					height: 50rpx;
					line-height: 50rpx;
					width: 100%;
					color: #959595;

				}

				.name {
					display: flex;
					height: 80rpx;
					line-height: 80rpx;

					.text {
						width: 65%;
						overflow: hidden;
						text-overflow: ellipsis;
						white-space: nowrap;
						position: absolute;

						text {
							margin: 0 10rpx;
							font-size: 28rpx;
							color: #109EF8;
						}
					}
				}


			}
		}

	}

	.bottom {
		height: 210rpx;
		color: #959595;
		line-height: 210rpx;
		text-align: center;
		font-size: 16px;
	}

	.content {
		padding-left: 4px;
		padding-right: 4px;
		padding-top: 1px;
		padding-bottom: 4px;
		background-color: #F5F5F5;
	}

	.line {
		margin-top: 4px;
		width: 100%;
		height: 2rpx;
		background: #aaa;
	}
</style>
